/*
pGina ldapAuth code - based upon skeleton code for pGina plugin development
Copyright (C) 2002 Micah Cooper

This program is free software; you can redistribute it and/or
modify it under the terms of the GNU General Public License
as published by the Free Software Foundation; either version 2
of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
GNU General Public License for more details.

You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.

Email: coopermj@muohio.edu
Snail Mail:
	Micah Cooper
	212A Kreger Hall
	Miami University
	Oxford OH  45056
*/

// Define macro's for exporting methods
#define LDAPAUTH_API extern "C" __declspec(dllexport)

// Define the pGinaInfo Structure
typedef struct pGinaInfo {
		LPTSTR pathMSGina;
		LPTSTR pathPlugin;
		LPTSTR pathProfile;
		LPTSTR mapPaths;
		LPTSTR Username;
		LPTSTR Password;
		LPTSTR homeDir;
		BOOL isAdmin;
		BOOL disabled;
		int authType;
		HANDLE hUser;
		LPTSTR userGroups;
		LPTSTR userDescription;
		LPTSTR userFullName;
		BOOL allowPassChange;
		LPTSTR errorString;
		LPTSTR defaultDomain;
		BOOL Reserved3;
		BOOL Reserved4;
} pGinaInfo ;

// Export these methods...
LDAPAUTH_API BOOL UserLogin(LPTSTR, LPTSTR,pGinaInfo *);			
LDAPAUTH_API BOOL ChangeUserPassword(LPTSTR,LPTSTR,LPTSTR);
LDAPAUTH_API LPCTSTR AboutPlugin(void);
LDAPAUTH_API void ChangePluginSettings(void);
LDAPAUTH_API void LoginHook(pGinaInfo *);
LDAPAUTH_API void LogoutHook(pGinaInfo *);
LDAPAUTH_API BOOL IsRequired(void);